home *** CD-ROM | disk | FTP | other *** search
- /* ShowMag.pvrx Copyright ©1991 by Stylus, Inc. */
- /* Author: Ross Cunniff, August 28, 1991 */
- Address 'ProVector'
- Options Results
-
- /* This macro flashes the highlight points of all of the magnetized */
- /* objects in the current project. It requres ProVector version 2.1 */
- /* to run. On faster systems (e.g. Amiga 3000) you may want to increase */
- /* the number of times that the points are flashed. You can do this by */
- /* tweaking the variable named NumFlash, below. */
- NumFlash = 5
-
- /* Get exclusive access to ProVector */
- 'Lock WAIT'
-
- /* Get the list of magnetized objects */
- 'GetMagnets Mag'; n = Result
-
- /* Get the initial state of the magnetized objects */
- i = 0
- do while i < n
- Obj = Mag.i
- 'Selected Obj'
- sel.i = Result
- i = i + 1
- end
-
-
- /* Flash the highlight points */
- NumFlash = NumFlash * 2 /* Times two since we're counting on AND off */
- nflash = 0
- do while nflash < NumFlash
- i = 0
- do while i < n
- Obj = Mag.i
- if sel.i ~= 0 then do
- sel.i = 0
- 'UnSelect Obj'
- end
- else do
- sel.i = 1
- 'SelectObj Obj'
- end
- i = i + 1
- end
- nflash = nflash + 1
- end
-
- /* At this point, since we toggled selection an even number of times, */
- /* the selection state is the same as it was initially. Release exclusive */
- /* access to ProVector */
- 'UnLock'
-
- /* All done! */
-